package com.wz.project.sap.MATERIAL.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.wz.project.sap.MATERIAL.mapper.ZflWmsGetMaterialMapper;
import com.wz.project.sap.MATERIAL.domain.ZflWmsGetMaterial;
import com.wz.project.sap.MATERIAL.service.IZflWmsGetMaterialService;
import com.wz.common.utils.text.Convert;

/**
 * 物料主数据Service业务层处理
 * 
 * @author wz
 * @date 2022-09-14
 */
@Service
public class ZflWmsGetMaterialServiceImpl implements IZflWmsGetMaterialService 
{
    @Autowired
    private ZflWmsGetMaterialMapper zflWmsGetMaterialMapper;

    /**
     * 查询物料主数据
     * 
     * @param MATNR 物料主数据ID
     * @return 物料主数据
     */
    @Override
    public ZflWmsGetMaterial selectZflWmsGetMaterialById(String MATNR)
    {
        return zflWmsGetMaterialMapper.selectZflWmsGetMaterialById(MATNR);
    }

    /**
     * 查询物料主数据列表
     * 
     * @param zflWmsGetMaterial 物料主数据
     * @return 物料主数据
     */
    @Override
    public List<ZflWmsGetMaterial> selectZflWmsGetMaterialList(ZflWmsGetMaterial zflWmsGetMaterial)
    {
        return zflWmsGetMaterialMapper.selectZflWmsGetMaterialList(zflWmsGetMaterial);
    }

    /**
     * 新增物料主数据
     * 
     * @param zflWmsGetMaterial 物料主数据
     * @return 结果
     */
    @Override
    public int insertZflWmsGetMaterial(ZflWmsGetMaterial zflWmsGetMaterial)
    {
        return zflWmsGetMaterialMapper.insertZflWmsGetMaterial(zflWmsGetMaterial);
    }

    /**
     * 修改物料主数据
     * 
     * @param zflWmsGetMaterial 物料主数据
     * @return 结果
     */
    @Override
    public int updateZflWmsGetMaterial(ZflWmsGetMaterial zflWmsGetMaterial)
    {
        return zflWmsGetMaterialMapper.updateZflWmsGetMaterial(zflWmsGetMaterial);
    }

    /**
     * 删除物料主数据对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteZflWmsGetMaterialByIds(String ids)
    {
        return zflWmsGetMaterialMapper.deleteZflWmsGetMaterialByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除物料主数据信息
     * 
     * @param MATNR 物料主数据ID
     * @return 结果
     */
    @Override
    public int deleteZflWmsGetMaterialById(String MATNR)
    {
        return zflWmsGetMaterialMapper.deleteZflWmsGetMaterialById(MATNR);
    }
}
